<!DOCTYPE html 
PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN"
"http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml"
    dir="{% if LANGUAGE_BIDI %}rtl{% else %}ltr{% endif %}"
    xml:lang="{% firstof LANGUAGE_CODE 'en' %}"
    lang="{% firstof LANGUAGE_CODE 'en' %}">
    <head>
        <title>{% block title %}{% endblock %} - Google App Engine Series</title>

        {% block css %}
        {% endblock %}

        {% block preload_js %}
        {% endblock %}

        {% block extra-head %}{% endblock %}
    </head>

    <body>
        <div id="header">
            <h1 id="">Very simple blog :)</h1>
        </div>

        <div class="menu">
            <a href="{% url core.views.list_posts %}">All posts</a>
            <a href="{% url core.views.new_post %}">New post</a>
            {% if user.is_authenticated %}
            <a href="{% url django.contrib.auth.views.logout %}">Logout</a>
            {% else %}
            <a href="{% url django.contrib.auth.views.login %}">Login</a>
            {% endif %}
        </div>

        <div class="columns">
            <div id="content" class="column">
                {% block content-header %}
                {% if error %}<div class="error">{{ error }}</div>{% endif %}
                {% if info %}<div class="info">{{ info }}</div>{% endif %}
                {% if messages %}
                {% for message in messages %}
                <div class="info">{{ message }}</div>
                {% endfor %}
                {% endif %}
                {% endblock %}

                {% block content %}{% endblock %}
            </div>

            <div id="sidebar" class="column">
                {% block sidebar %}
                {% endblock %}
            </div>
        </div>

        <div id="footer">
            <p>Powered by <a href="http://www.allbuttonspressed.com/projects/django-nonrel" target="_blank" rel="nofollow" title="Django-nonrel">Django-nonrel</a>, built by <a href="http://www.franciscosouza.net" target="_blank" title="Francisco Souza">Francisco Souza</a></p>
        </div>

        {% block js %}
        {% endblock %}
    </body>
</html>
